<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Strict//EN">
<html>

<head>
<meta http-equiv="Content-Language" content="en-us">
<title>simCheckProximitySensorEx2</title>
<link rel="stylesheet" type="text/css" href="../../style.css">
</head>

<body>

<div align="center">
<table class=allEncompassingTable >
 <tr>
  <td >
<p><a href="../../index.html" TARGET="_top"><img src="../images/homeImg.png"></a></p>

<h1>Regular API function</h1>
<h3 class=subsectionBar><a name="simCheckProximitySensorEx2" id="simCheckProximitySensorEx2"></a>simCheckProximitySensorEx2 / sim.checkProximitySensorEx2 </h3>
<table class=apiTable>
<tr class=apiTableTr> 
<td class=apiTableLeftDescr>
Description 
</td> 
<td class=apiTableRightDescr>Checks whether the proximity sensor detects the indicated points, segments or triangles. Detection is silent (no visual feedback). See also <a href="simReadProximitySensor.htm">sim.readProximitySensor</a> and <a href="simCheckProximitySensorEx.htm">sim.checkProximitySensorEx</a>.<br></td>
</tr> 
<tr class=apiTableTr> 
<td class=apiTableLeftCSyn>
C synopsis
</td> 
<td class=apiTableRightCSyn>simInt simCheckProximitySensorEx2(simInt sensorHandle,simFloat* vertexPointer,simInt itemType,simInt itemCount,simInt detectionMode,simFloat detectionThreshold,simFloat maxAngle,simFloat* detectedPoint,simFloat* normalVector)<br></td> 
</tr> 
<tr class=apiTableTr> 
<td class=apiTableLeftCParam>C parameters</td> 
<td class=apiTableRightCParam>
<div><strong>sensorHandle</strong>: handle of the proximity sensor object</div>
<div><strong>vertexPointer</strong>: a pointer to vertices</div>
<div><strong>itemType</strong>: 0 for points, 1 for segments and 2 for triangles</div>
<div><strong>itemCount</strong>: the number of items that vertexPointer points at</div>
<br>
<div>For the other parameters, see the description in <a href="simCheckProximitySensorEx.htm">simCheckProximitySensorEx</a>. (simCheckProximitySensorEx2 doesn't support occlusion checking)<br>
</div>
</td> 
</tr> 
<tr class=apiTableTr> 
<td class=apiTableLeftCRet>
C return value
</td> 
<td class=apiTableRightCRet>
<div>-1 if operation was not successful, otherwise 0 (no detection) or 1 (detection)<br>
</div>
</td> 
</tr> 
<tr class=apiTableTr> 
<td class=apiTableLeftLSyn>
Lua synopsis
</td> 
<td class=apiTableRightLSyn>int result,float distance,table[3] detectedPoint,table[3] normalVector=sim.checkProximitySensorEx2(int sensorHandle,table[] vertices,int itemType,int itemCount,int mode,float threshold,float maxAngle)<br></td> 
</tr> 
<tr class=apiTableTr> 
<td class=apiTableLeftLParam>Lua parameters</td> 
<td class=apiTableRightLParam>
<div><strong>sensorHandle</strong>: handle of the proximity sensor object</div>
<div><strong>vertices</strong>: a table containing vertices</div>
<div><strong>itemType</strong>: 0 for points, 1 for segments and 2 for triangles</div>
<div><strong>itemCount</strong>: the number of items that the 'vertices' table contains</div>
<br>
<div>For the other parameters, see the description in <a href="simCheckProximitySensorEx.htm">sim.checkProximitySensorEx</a>. (sim.checkProximitySensorEx2 doesn't support occlusion checking)
</div>
</td> 
</tr> 
<tr class=apiTableTr> 
<td class=apiTableLeftLRet>
Lua return values
</td> 
<td class=apiTableRightLRet>
<div><strong>result</strong>: 0 (not detected) or 1 (detected)</div>
<br>
<div>For the other return values, see the description in <a href="simCheckProximitySensorEx.htm">sim.checkProximitySensorEx</a>.
</div>
</td> 
</tr> 
</table> 


<br>
</td>
</tr>
</table>
</div>
</body>
</html>
